<!--
To change this template, choose Tools | Templates
and open the template in the editor.
-->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">






        <script type="text/javascript" src="js/jquery-1.3.1.min.js"></script>
    <script type="text/javascript" src="js/jquery.dragndrop.js"></script>
    <style type="text/css">
        body,html
        {
            font-family:Calibri;
            font-size:12px;
            height:1000px;
            line-height:18px;
            }
        p
        {
        	height:20px;
        	}
        .dragDiv
        {
        	width:150px;
        	background-color:black;
            border:1px solid black;
            position:absolute;
            left:1100px;
            top:1300px;
        	}
        .dragDiv h5
        {
        	background-color:#B2D3F5;
        	padding:5px;
            margin:1px;
        	}
        .dragDiv div
        {
        	padding:5px;
        	margin-bottom:0px;
            }
       
    </style>
    <script type="text/javascript">
        $().ready(function() {
            $('.dragDiv').Drags({
                handler: '.handler',
                onMove: function(e) {
                    $('.content').html('Div Position:(Left:' + e.pageX + ' ,Top:' + e.pageY + ')');
                },
                onDrop:function(e){
                    $('.content').html('dropped!');
                }
            });


        });
    </script>












        <title></title>
    </head>
    <body >
        <h1 align="center">  </h1>
        <font color="gray">
        
        <?php
            $k=0;
            $conn=mysql_connect("localhost","root");
            mysql_select_db("ShoppingCart",$conn);
            $result=mysql_query("SELECT * FROM products WHERE category=\"".$_GET["foo"]."\"",$conn);
            while($row=mysql_fetch_array($result)){
                $k+=1;
                
                echo "<img src=\"".$row[thumbnail]."\" width=\"150\" height=\"100\">";
                
                echo "</br>";
                echo "<font size=\"5\" face=\"Calibri\">".$row[name]."</font>";
                echo "</br>";
                echo "<font size=\"4\" face=\"Trebuchet MS\">".$row[shortdescription]."</font>";
                echo "</br>";
                echo "Rs.".$row[price];
                echo "</br>";
                echo " <a href=\"index.php?su=".$row["name"]."\">"."View More"."</a>";
                echo "</br>";
                echo "</br>";
                echo "<div class=\""."dragDiv"."\"> <h5 class=\"handler\"><img src=\"".$row[thumbnail]."\" width=\"50\" height=\"50\"></h5>
    <div class=\"content\">Drag me to cart to add to cart.</div>
</div>";
                echo "</br>";
                echo "</br>";
                echo "</br>";
                echo "</br>";
                echo "</br>";
            }
            mysql_close($conn);
            
        ?>
            </font>
    </body>
</html>
